<div id="comments">
    <?php if (post_password_required()) : ?>
        <p class="nopassword"><?php _e('This post is password protected. Enter the password to view any comments.', 'bhutanese_refugees'); ?></p>
    </div><!-- #comments -->
    <?php
    /* Stop the rest of comments.php from being processed,
     * but don't kill the script entirely -- we still have
     * to fully load the template.
     */
    return;
endif;
?>

<?php
$commentType = "feedback";
// You can start editing here -- including this comment!
?>

<?php if (have_comments()) : ?>
    <!--			<h3 id="comments-title"><?php
    printf(_n('One Response to %2$s', '%1$s Responses to %2$s', get_comments_number(), 'bhutanese_refugees'), number_format_i18n(get_comments_number()), '<em>' . get_the_title() . '</em>');
    ?></h3>-->

    <?php if (get_comment_pages_count() > 1 && get_option('page_comments')) : // Are there comments to navigate through?  ?>
        <div class="navigation">
            <div class="nav-previous"><?php previous_comments_link(__('<span class="meta-nav">&larr;</span> Older ' . ucfirst($commentType . "s"), 'bhutanese_refugees')); ?></div>
            <div class="nav-next"><?php next_comments_link(__('Newer ' . ucfirst($commentType . "s") . ' <span class="meta-nav">&rarr;</span>', 'bhutanese_refugees')); ?></div>
        </div> <!-- .navigation -->
    <?php endif; // check for comment navigation  ?>

    <ol class="commentlist">
        <?php
        /* Loop through and list the comments. Tell wp_list_comments()
         * to use bhutanese_refugees_comment() to format the comments.
         * If you want to overload this in a child theme then you can
         * define bhutanese_refugees_comment() and that will be used instead.
         * See bhutanese_refugees_comment() in bhutanese_refugees/functions.php for more.
         */
        wp_list_comments(array('callback' => 'bhutanese_refugees_feedback'));
        ?>
    </ol>

    <?php if (get_comment_pages_count() > 1 && get_option('page_comments')) : // Are there comments to navigate through?  ?>
        <div class="navigation">
            <div class="nav-previous"><?php previous_comments_link(__('<span class="meta-nav">&larr;</span> Older ' . ucfirst($commentType . "s"), 'bhutanese_refugees')); ?></div>
            <div class="nav-next"><?php next_comments_link(__('Newer ' . ucfirst($commentType . "s") . ' <span class="meta-nav">&rarr;</span>', 'bhutanese_refugees')); ?></div>
        </div><!-- .navigation -->
    <?php endif; // check for comment navigation  ?>

<?php
else : // or, if we don't have comments:

    /* If there are no comments and comments are closed,
     * let's leave a little note, shall we?
     */
    if (!comments_open()) :
        ?>
        <p class="nocomments"><?php _e(ucfirst($commentType . "s") . ' are closed.', 'bhutanese_refugees'); ?></p>
    <?php endif; // end ! comments_open() ?>

<?php endif; // end have_comments() ?>

<?php
/* $args = array(
  'title_reply' => __( 'Leave a '. ucfirst($commentType)),
  'title_reply_to' => __( 'Leave a '.ucfirst($commentType).' to %s' ),
  'cancel_reply_link' => __( 'Cancel '.ucfirst($commentType) ),
  'label_submit' => __( 'Post '.ucfirst($commentType) ),
  'comment_field' => '<p class="comment-form-comment"><textarea id="comment" name="comment" cols="45" rows="8" aria-required="true"></textarea></p>',
  'comment_notes_after' => '<p class="form-allowed-tags">' . sprintf( __( 'You may use these <abbr title="HyperText Markup Language">HTML</abbr> tags and attributes: %s' ), ' <code>' . allowed_tags() . '</code>' ) . '</p>',
  );
  comment_form($args);
 */
global $current_user;
      get_currentuserinfo();
?>

<div id="respond">
    <h3 id="reply-title">Leave Your Own Feedback <small><?php cancel_comment_reply_link('Cancel Feedback'); ?></small></h3>
    <form id="commentform" method="post" action="<?php echo get_option('siteurl'); ?>/wp-comments-post.php">
        <?php if (is_user_logged_in()) : ?>
                <p class="comments-logged-in-as"><?php _e("Logged in as", "bhutanese_refugees"); ?> <a href="<?php echo get_option('siteurl'); ?>/wp-admin/profile.php"><?php echo $user_identity; ?></a>. <a href="<?php echo wp_logout_url(get_permalink()); ?>" title="<?php _e("Log out of this account", "bhutanese_refugees"); ?>"><?php _e("Log out", "bhutanese_refugees"); ?> <?php _e("&raquo;", "bhutanese_refugees"); ?></a></p>
            <?php else : ?>
                <ul id="comment-form-elements" class="clearfix feedback_ul">
                    <li>
                        <label for="author"><?php _e("Name", "bhutanese_refugees"); ?> <span class="required">*</span></label>
                        <input type="text" name="author" id="author" value="<?php echo esc_attr($comment_author); ?>" placeholder="<?php _e('Your Name*', 'bhutanese_refugees'); ?>" tabindex="1" aria-required='true' />
                    </li>
                    <li>
                        <label for="email"><?php _e("E-mail", "bhutanese_refugees"); ?> <span class="required">*</span> <small><?php _e("(will not be published)", "bhutanese_refugees"); ?></small></label>
                        <input type="email" name="email" id="email" value="<?php echo esc_attr($comment_author_email); ?>" placeholder="<?php _e('Your E-Mail*', 'bhutanese_refugees'); ?>" tabindex="2" aria-required='true' />
        		  
                    </li>
                    <li>
                        <label for="url"><?php _e("Website", "bhutanese_refugees"); ?></label>
                        <input type="url" name="url" id="url" value="<?php echo esc_attr($comment_author_url); ?>" placeholder="<?php _e('Got a website?', 'bhutanese_refugees'); ?>" tabindex="3" />
                    </li>
                </ul>
            <?php endif; ?>
            <p>
                <?php 
                $settings = array(
                    'media_buttons'=>false,
                    'textarea_name'=>'comment',
                    'textarea_rows'=>8,
                    'tabindex'=>4
                );
                wp_editor( "", "comment-feedback", $settings ); ?> 
<!--                <textarea name="comment" id="comment" placeholder="<?php _e('Your feedback here...', 'bhutanese_refugees'); ?>" tabindex="4"></textarea>-->
            </p>

            <p class="form-submit">
                <input name="submit" type="submit" id="submit" class="button" tabindex="5" value="<?php _e('Post Feedback', 'bhutanese_refugees'); ?>" />
                <?php comment_id_fields(); ?>
            </p>

            <div class="alert info">
                <p id="allowed_tags" class="small"><strong>XHTML:</strong> <?php _e('You can use these tags', 'bhutanese_refugees'); ?>: <code><?php echo allowed_tags(); ?></code></p>
            </div>
            <?php do_action('comment_form', $post->ID); ?>
    </form>
</div>
</div><!-- #comments -->
